package com.alibaba.dubbo.consumer;

import com.alibaba.dubbo.demo.DemoService;
import org.springframework.context.support.ClassPathXmlApplicationContext;

import java.util.List;

/**
 * 消费者2
 * @author:  wyc
 * @date:    2018/6/20 18:49
 */
public class Consumer {
    public static void main(String[] args) {

        //测试常规服务
        ClassPathXmlApplicationContext context = new ClassPathXmlApplicationContext("consumer.xml");
        context.start();
        System.out.println("########################################## Consumer2 start");

        DemoService demoService = context.getBean(DemoService.class);
        List<String> list = demoService.getPermissions(1L);
        System.out.println("######################################### Consumer2：" + list);
    }
}
